#ifndef ASSEMBLY_TYPES_H
#define ASSEMBLY_TYPES_H

#include <stdlib.h>
#include <stdint.h>

#define POLY_FACTOR 29
#define POLY_DEVIDER 65537
#define MAX_FUNC_ID 65535
#define MAX_VAR_AMMOUNT 65535

#define IS_FUNC_SIGN_CHAR(c, l) ( (((c) >= 'A') && ((c) <= 'Z')) || \
								(((c) >= 'a') && ((c) <= 'z')) || \
								(((c) == '-') && ((l) != 0)) || \
								((c) == '_') )

typedef struct STRLST {/*STRing LiST*/
						struct STRLST *next;
						char *string;
						uint16_t id;
						} StringList, *PStringList;

typedef struct LBLS {/*LaBeLS*/
						struct LBLS *next;
						char label[32];
						size_t position;
						} Labels, *PLabels;

typedef struct LBLSL {/*LaBeLS List*/
						struct LBLSL *next;
						char label[32];
						size_t position;
						unsigned long long int line;
						} LabelsList, *PLabelsList;

typedef struct BTCD {/*ByTeCoDe*/
						unsigned char *bytecode;
						PLabels labels;
						PLabelsList queue;
						PStringList strings;
						size_t bytecodeSize;
						} Bytecode, *PBytecode;

typedef struct FUNCSLST {//FUNCtionS LiST
						struct FUNCSLST *next;
						char *signature;
						unsigned char *bytecode;
						uint32_t bytecodeSize;
						uint32_t varAmmount;
						uint32_t argAmmount;
						uint16_t id;
						} FunctionsList, *PFunctionsList;

#endif
